home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
BBS in a Box 7
/
BBS in a Box - Macintosh - Volume VII (BBS in a Box) (January 1993).iso
/
Files
/
Prog
/
M
/
MacStarter.cpt
/
globals-MacStarter.h
< prev
next >
Wrap
Text File
|
1992-10-10
|
2KB
|
74 lines
/* MacStarter is a shell for simple Macintosh applications shell written in
THINK C, with some small use of its object-oriented features.
The whole system is described in a README file that should be in the
same folder with this file, which has full details on the stuff
defined here.
*/
extern EventRecord gEvent;
extern int gClickCount;
extern Rect gWindowRect;
extern Handle gMenuBar;
extern long gEventWaitTime;
typedef enum {
hasVScroll = 1,
hasHScroll = 2,
hasGoAway = 4,
hasZoom = 8,
hasGrow = 16 }
WindowFeatures;
class xWindow : indirect {
protected:
short features;
int topScrollOffset,bottomScrollOffset;
int leftScrollOffset,rightScrollOffset;
int minH, maxH, minV, maxV;
int hLinesPerPage,vLinesPerPage;
ControlHandle hScroll,vScroll;
WindowPtr theWindow;
xWindow *nextWindow;
public:
virtual void OpenInRect(Str255 title, int left, int top, int right, int bottom);
void OpenFullScreen(Str255 title);
void Open(Str255 title);
virtual short Close(void);
void doEvent(void);
static int Window2XWindow(WindowPtr win, xWindow** xWin);
protected:
virtual void SetDefaults(void);
void GetTitle(Str255 name);
void SetTitle(Str255 name);
void ForceRedraw(Rect *badRect);
int GetHVal(void);
int GetVVal(void);
void SetHVal(int val);
void SetVVal(int val);
int GetHMax(void);
int GetVMax(void);
void SetHMax(int val);
void SetVMax(int val);
void SetHLinesPerPage(short hLines);
void SetVLinesPerPage(short vLines);
virtual void doKey(char ch);
virtual void doContentClick(Point localPt);
virtual void adjustToNewSize(void);
virtual void doRedraw(Rect* badRect);
virtual void doActivate(int active);
virtual void doHScroll(int dh);
virtual void doVScroll(int dv);
private:
~xWindow(void);
void doBasicOpen(Str255 title, int left, int top, int right, int bottom);
void doClick(Point globalPt);
void doDrag(Point globalPt);
void doZoom(short partNum);
void doGrow(Point globalPt);
void doUpdate(void);
static pascal void ContinuousScroll(ControlHandle theControl, short partNum);
};
extern xWindow *xWindowList;